package com.lagou.order.feign;

import Com.lagou.common.pojo.Goods;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@FeignClient(name = "lagou-service-goods",fallback = GoodsFeignFallBack.class)
public interface GoodsFeign {

    /**
     * 通过商品id查询商品对象
     * @param id
     * @return
     */
    @GetMapping("/goods/query/{id}")
    public Goods queryById(@PathVariable Integer id);

    @GetMapping("/service/port")
    public String getPort();
}
